package cn.thoughtworks.school.entities;

public enum Operation {
    CREATE, UPDATE, DELETE, COPY, MOVE, UNKNOWN;

    public static Operation value(String operation) {
        switch (operation) {
            case "UPDATE":
                return Operation.UPDATE;
            case "CREATE":
                return CREATE;
            case "DELETE":
                return DELETE;
            case "COPY":
                return COPY;
            case "MOVE":
                return MOVE;
            default:
                return UNKNOWN;
        }
    }
}
